package cn.com.dcsgo.advice;

import cn.com.dcsgo.pointcut.RefPointCut;
import org.aspectj.lang.annotation.After;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.springframework.stereotype.Component;

/**
 * 引用切点表达式
 *
 * @author Dcsgo
 * @since 2025/2/6 15:27
 */
@Aspect
//@Component
public class Advice {
    /**
     * 通过全限定方法名来引用其他类的切点
     */
    @Before("cn.com.dcsgo.pointcut.RefPointCut.allService()")
    public void before() {
        System.out.println("Aspect of : " + getClass().getSimpleName());
    }
}
